<template>
  <el-container style="text-align: right; font-size: 12px">
    <el-backtop :bottom="60"></el-backtop>
    <!--********** 头部 -->
    <el-header style="height:auto" :class="addpadding">
      <e-header></e-header>
    </el-header>
    <!--********** 主体 -->
    <el-main style="height:auto" :class="bacColor">
      <e-contentFrame> </e-contentFrame>
      <e-contentTag> </e-contentTag>
      <e-contentBody> </e-contentBody>
      <!-- <e-advertisingSpace> </e-advertisingSpace> -->
    </el-main>

    <!--********** 底部 -->
    <el-footer style="height:auto">
      <e-footer></e-footer>
    </el-footer>
  </el-container>
</template>
<script>
import eHeader from "@/components/public/Header.vue";
import eContentFrame from "@/components/public/ContentFrame.vue";
import eFooter from "@/components/public/Footer.vue";
import eContentTag from "@/components/public/ContentTag.vue";
import eAdvertisingSpace from "@/components/public/AdvertisingSpace.vue";
import eContentBody from "@/components/public/ContentBody.vue";

export default {
  components: {
    eHeader,
    eContentFrame,
    eFooter,
    eContentTag,
    eAdvertisingSpace,
    eContentBody
  },
  data() {
    return {
      addpadding: "addpadding",
      bacColor: "#F0FFFE"
    };
  },
  created() {
    if (localStorage.getItem("background-color")) {
      let getColor = localStorage.getItem("background-color");
      let Colorarr = getColor.slice(1, 7);
      this.bacColor = Colorarr;
    } else {
      localStorage.setItem("background-color", "#F0FFFE");
      let getColor = localStorage.getItem("background-color");
      let Colorarr = getColor.slice(1, 7);
      this.bacColor = Colorarr;
    }
  },
  mounted() {
    // this.$bus.$on("changeColor", e => {
    //   this.addpadding = "addpadding";
    //   if (this.bacColor != e) {
    //     let Colorarr = e.slice(1, 7);
    //     this.bacColor = Colorarr;
    //   }
    // });
  },
  watch: {},
  methods: {}
};
</script>
<style lang="scss" scoped>
@import "../../assets/css/theme";
.el-container {
  overflow: hidden;
}
.el-main {
  overflow: hidden;
  padding: 0 0px;
}
.el-footer {
  padding: 0 0px;
}
.addpadding {
  padding: 0;
}
.DAEBFF {
  background: #daebff;
}
.F5F5FD {
  background: #f5f5fd;
}
.F0FFFE {
  background: #f0fffe;
}
</style>
